package com.fast.alden.admin.service;

import com.fast.alden.admin.entity.dto.ReadMessagesParam;
import com.fast.alden.data.model.SysMessage;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

import java.util.List;

public interface MessageCenterService {

    /**
     * 获取消息列表
     *
     * @param searchVo
     * @param pageable
     * @return
     */
    Page<SysMessage> messagePage(SysMessage searchVo, Pageable pageable);

    /**
     * 获取消息详情
     *
     * @param msgId
     * @return
     */
    SysMessage retrieveMessage(Long msgId);

    /**
     * 消息设为已读
     *
     * @param param
     */
    void readMessages(ReadMessagesParam param);

    int countUnreadMessage(Long receiverId);

    void sendMessage(List<SysMessage> messages);
}
